<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
      <% String path = request.getContextPath();%>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Insert title here</title>
</head>
<body>
		<form>
			角色：<input id="rname" name="rname"><br>
			<div class="content_wrap">
				<div class="zTreeDemoBackground left">
					<ul id="treeDemo" class="ztree"></ul>
				</div>
			</div>
		</form>
</body>
<script type="text/javascript">
//创建配置  角色绑定权限
var setting = {
	async: {
		enable: true,
		url: "/permissionsController/getzTree",
		autoParam: ["id", "name"]
	},
	data: {
		simpleData: {
			enable: true
		}
	},check: {
		enable: true,
		chkStyle: "checkbox",
		chkboxType: { "Y": "p", "N": "s" }
	}
};



//初始化树
$(document).ready(function(){
	$.fn.zTree.init($("#treeDemo"), setting);
});
</script>
</html>